package com.mtw.bbs.bbsUser.pojo.elasticsearch;




import lombok.Data;
import org.springframework.data.annotation.Id;
import org.springframework.data.elasticsearch.annotations.Document;
import org.springframework.data.elasticsearch.annotations.Field;
import org.springframework.data.elasticsearch.annotations.FieldType;


/**
 * 文章elasticsearch类
 */
@Data
@Document(indexName = "user_info")
public class UserESIndex {

    /**
     * 主键id
     */
    @Id
    @Field(type = FieldType.Keyword)
    private String id;


    /**
     * 账号
     */
    @Field(type = FieldType.Keyword)
    private String username;


    /**
     * 昵称
     */
    @Field(type = FieldType.Text, analyzer = "ik_max_word", searchAnalyzer = "ik_smart")
    private String displayName;

    /**
     * 头像
     */
    @Field(type = FieldType.Keyword)
    private String avatar;


    /**
     * 性别，（1是男，0为女）
     */
    @Field(type = FieldType.Integer)
    private Integer sex;


    /**
     * 用户类型
     */
    @Field(type = FieldType.Integer)
    private Integer userType;

    /**
     * 状态
     */
    @Field(type = FieldType.Integer)
    private Integer status;




}
